package com.mxf.code.service;

import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import com.mxf.code.dao.AppUserDao;
import com.mxf.code.entity.AppUser;
import org.springframework.stereotype.Service;

import java.util.ArrayList;
import java.util.List;

/**
 * app用户表(AppUser)表服务实现类
 *
 * @author makejava
 * @since 2023-02-20 10:19:33
 */
@Service("appUserService")
public class AppUserServiceImpl extends ServiceImpl<AppUserDao, AppUser> implements AppUserService {

    @Override
    public List<AppUser> listData() {
        List<AppUser> appUserList = new ArrayList<>();
        baseMapper.listData(null, resultContext -> {
            AppUser resultObject = resultContext.getResultObject();
            if (resultObject.getName() != null && resultObject.getName().contains("98")){
                appUserList.add(resultObject);
            }
        });
        return appUserList;
    }
}
